#include "any_type.hpp"
#include <cassert>
#include <cstring>
#ifdef _WIN32
    #include <windows.h>
#endif // _WIN32

struct MyStruct
{
    MyStruct()
    {
        memset(buff, 0, 100000);
    }

    char buff[100000];
};

int main()
{
#ifdef _WIN32
    SetConsoleCP(65001);
    SetConsoleOutputCP(65001);
#endif // _WIN32
    for (int i = 0; i < 1000000; ++i)
    {
        AnyType any1(MyStruct {});
        AnyType any2(any1);
        const AnyType any3(std::move(any2));
        any2 = any3;
        any1 = std::move(any2);
        any1 = 10;
        int* value = any1.DynamicCast<int>();
        assert(value);
    }
    return 0;
}